/**
 * @param {number[]} time
 * @param {number[][]} fruits
 * @param {number} limit
 * @return {number}
 */
 var getMinimumTime = function(time, fruits, limit) {
  let ans = 0
  for(const [t, x] of fruits) {
    ans += time[t] * Math.ceil(x/limit)
  }
  return ans
};